﻿<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/static/include/top.jsp"%>
<script>document.title="导出终审通过报表";</script>
<script src="${baseURL}/static/js/calendar.js"></script>
<script type="text/javascript">
function openEditWin(url,tit){
	openWin(tit,url,1200,600);
}

function openViewWin(id){
	openWin("审批历史","${ctx}/data/view?id="+id,800,600);
}
function xxx(){
	location.reload(true);
}
</script>

<table>
	<tbody>

		<tr>
			<th><img src="${ctx}/static/images/pages/cen/rig/ico_01.png"
				align="absmiddle">&nbsp;导出终审通过报表</th>
		</tr>
		<tr class="tab_grey">
			<td>
				<form name="searchForm" action="" method="get">
					<input type="hidden" name="p" value="1" /> 
					 <span class="tab_text"> 单位名称： </span> <input id="unitName"
						type="text" name="unitName" value="${param['unitName']}" size="20"
						class="tab_textbut" />
						<span class="tab_text">开始时间:</span>
			<input
				id="searchDate" name="searchDate" onclick="calendar.show(this);"
				value="${formdata.startTime}" type="text"  class="tab_textbut" >
			<span class="tab_text">结束时间：</span>
			
			<input
				id="endDate" name="endDate" onclick="calendar.show(this);"
				value="${formdata.endTime}" type="text"  class="tab_textbut" >
			
						
				
					<a class="tab_but" href="#"
						onclick="searchForm.action='${baseURL}/dataManage/expFinalPass';searchForm.submit();return false;">查询</a>
					<a class="tab_but" href="#" onclick="clearInput();return false;">清空</a><br>

					<a class="tab_but02" href="#"
						onclick="searchForm.action='${baseURL}/dataManage/downloadFinalPass';searchForm.submit();">导出终审通过报表</a>
				</form>

				<script>
		
		$("#unitName").val("${param['unitName']}");
		$("#searchDate").val("${param['searchDate']}");
		$("#endDate").val("${param['endDate']}");
		
		
		function clearInput() {
			
			$("#unitName").val("");
			$("#searchDate").val("");
			$("#endDate").val("");
		}
		</script> <iframe name="upload" width="0" height="0" frameborder="0"></iframe>
			</td>
		</tr>

	</tbody>
</table>



<br />
<c:if test="${empty obj.operationResult}">
	<b>没有符合条件的记录。</b>
</c:if>
<c:if test="${not empty obj.operationResult}">

	<table id="listTable">
	<tbody>
		<tr>
		
				<th width="20%">报表类型</th>
				<th width="8%">频率</th>
				<th width="8%">频率时段</th>
				<th width="14%">报出时间</th>
				<th width="20%">填报单位</th>
				<th width="10%">填表人</th>
				<th width="10%">审批历史</th>
				<th>操作</th>
				
			
		</tr>
		<c:forEach var="oneRow" items="${obj.operationResult}">

			<tr>
				
				<td align="left" >${oneRow.reportName}</td>
				<td align="left" class="tab_td_rig">${oneRow.reportTimetype}</td>
				<td align="left" >${oneRow.reportYear}</td>
				<td align="left" >${oneRow.reportDate}</td>
				<td align="left" >${oneRow.reportUnit}</td>
				<td align="left" >${oneRow.reportFillAdmin}</td>
				
			<td align="left">
			<a href="#" onclick="openViewWin('${oneRow.id}')"><img src="${baseURL}/static/images/tab/ico_01.png" width="16" height="16" border="0" align="absmiddle"/>历史</a></td>
		<td align="left">
			<a href="#" onclick="openEditWin('http://localhost:8080/jsme-das-lan/reports/service.do?method=showReportInfo&reportOperatorId='+'${userId}'+'&reportId='+'${oneRow.id}','查看'+'${oneRow.reportDomainName}')"><img src="${baseURL}/static/images/tab/ico_01.png" width="16" height="16" border="0" align="absmiddle"/>详情</a>
			
		</td>
			</tr>
		</c:forEach>
		<tr class="tab_grey">
				<td colspan="7" align="center" valign="middle" class="tab_white">
				<div class="pagination"> 
					<%@ include file="../include/listpage.jsp"%>
				</div>
				<div class="clear"></div>
				</td>
			</tr>	
		
		</tbody>
	</table>
	<script>

function selectAll(checkAllFlag) {
	var checkArray = document.getElementsByName("chk");
	for (var i = 0; i < checkArray.length; i++) {
		checkArray[i].checked = checkAllFlag;
	}
}

function getRep(ptype) {
	
	var myDate = new Date();
	pyear=myDate.getFullYear(); 
	alert(pyear);
	$.getJSON("${baseURL}/unit/getReps?year="+pyear+"&typeId="+ptype, function(data) {
		$("#reportTypeId").empty();
		$("#reportTypeId").append( "<option value='0'>请选择..</option>" );
		
	 	$.each(data, function(i, item) {
            $("#reportTypeId").append( "<option value='" + item.id + "'>" + item.typeName + "</option>" );
        });
 });
}
</script>
</c:if>

<%@ include file="/static/include/bottom.jsp"%>
